//
//  ReleaseViewController.m
//  AnXin100
//
//  Created by Sakura on 2018/11/13.
//  Copyright © 2018 tzhg. All rights reserved.
//

#import "ReleaseViewController.h"
#import "UITextView+WZB.h"
#import "ChoicePhotoView.h"

@interface ReleaseViewController ()
@property (nonatomic, strong) ChoicePhotoView *choicePhoto;
@end

@implementation ReleaseViewController

- (void)viewDidLoad {
    
    [super viewDidLoad];
    self.view.backgroundColor = [UIColor whiteColor];
    UITextView *textView = [[UITextView alloc] initWithFrame:CGRectMake(10, Hn + 10, SCREEN_WIDTH - 20, 250)];
    textView.layer.cornerRadius = 5;
    textView.layer.borderColor = COLOR_LINE.CGColor;
    textView.layer.borderWidth = 1;
    textView.wzb_placeholder = @"分享您的笔记";
    [self.view addSubview:textView];
    
    
    UIButton *releaseBtn = [UIButton buttonWithType:UIButtonTypeCustom];
    releaseBtn.frame = CGRectMake(0, SCREEN_HEIGHT - 44, SCREEN_WIDTH, 44);
    releaseBtn.backgroundColor = COLOR_GREEN;
    [releaseBtn setTitle:@"发布" forState:UIControlStateNormal];
    releaseBtn.titleLabel.font = [UIFont systemFontOfSize:14];
    [self.view addSubview:releaseBtn];
    
    
    _choicePhoto = [[ChoicePhotoView alloc] initWithFrame:CGRectMake(10, CGRectGetMaxY(textView.frame) + 10, SCREEN_WIDTH - 20, SCREEN_HEIGHT - CGRectGetMaxY(textView.frame) - 20 - 44)];
    _choicePhoto.viewController = self;
    _choicePhoto.takingPictures = YES;
    _choicePhoto.choicePictures = YES;
    _choicePhoto.choiceViedos = NO;
    _choicePhoto.orginalImage = NO;
    _choicePhoto.GIF = NO;
    _choicePhoto.takeBtn = YES;
    _choicePhoto.tailoring = NO;
    _choicePhoto.CircularCut = NO;
    _choicePhoto.multiSelectViedoAndGif = NO;
    _choicePhoto.recordViedo = NO;
    _choicePhoto.showNumber = YES;
    _choicePhoto.maxChoiceImage = 9;
    _choicePhoto.lineImageNumber = 4;
    _choicePhoto.type = Transverse;
    [self.view addSubview:_choicePhoto];
}



@end
